﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace LoopRefactoring
{
    class Program
    {
        static void Main(string[] args)
        {
            int[] valuesArr = new int[100];
            bool isFound = false;
            valuesArr[30] = 20;
            int currentCell = 0;
            int expectedValue = 20;

            for (int i = 0;i < 100;i++)
            {
                if (currentCell % 10 == 0)
                {
                    Console.WriteLine(valuesArr[i]);
                    if (valuesArr[i] == expectedValue)
                    {
                        isFound = true;
                        break;
                    }
                }
                else
                {
                    Console.WriteLine(valuesArr[i]);
                }
                currentCell++;
            }

            // More code here
            if (isFound)
            {
                Console.WriteLine("Value Found");
            }

        }
    }
}
